
#include "object3d.h"
#include <Windows.h>
#include <gl\GL.h>
#include <gl\GLU.h>

Object3D::Object3D()
{

}

void Object3D::render()
{
	if(_coords.size() != _colors.size() || _coords.size() != _normals.size())
	{
		return;
	}
	
	for(unsigned int i = 0; i < _coords.size(); i++)
	{
		Vec3 coord = _coords[i];
		Vec3 color = _colors[i];
		Vec3 normal = _normals[i];
		glNormal3f(normal.getX(), normal.getY(), normal.getZ());
		glColor3f(color.getX(), color.getY(), color.getZ());
		glVertex3f(coord.getX(), coord.getY(), coord.getZ());
	}
}